﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

using Microsoft.Extensions.DependencyInjection;

using Xc.Logics.HyperTerminalCore.Udp.Models;
using Xc.Logics.HyperTerminalCore.Udp.Views;
using Xc.Views.Core;

namespace Xc.Logics.HyperTerminalCore.Udp
{
    [Boot("UDP超级终端")]
    public class StartUp: ApplicationBooster<AppSetting>
    {
        protected override void BeforeBuild(IServiceCollection serviceDescriptors)
        {
            serviceDescriptors.AddTransient<MainView>();
            serviceDescriptors.AddSettingService<AppSetting>();
            serviceDescriptors.AddEncodingServcie();
            serviceDescriptors.AddTransient<PackageView>();
            serviceDescriptors.AddSocketService();
            base.BeforeBuild(serviceDescriptors);
        }
        public MainView GetMainElement()
        {
            return this.GetMainElement<MainView>();
        }
    }

}
